import request from '@/axios'

export function getTableData(){
  return request.get('/home/getTableData')
}

export function getCountData(){
  return request.get('/home/getCountData')
}

export function getChartData(){
  return request.get('/home/getChartData')
}

export function getUserTableData(config){
  return request.get('/user/getUserTableData', {
    params: {...config}
  })
}

export function deleteUser(data: object){
  return request.get('/user/deleteUser', {
    params: {...data}
  })
}

export function addUser(data: object){
  return request.post('/user/addUser', data)
}

export function editUser(data: object){
  return request.post('/user/editUser', data)
}

export function getMenu(params){
  return request.post('/permission/getMenu', params)
}
